# -*- coding: utf-8 -*-

# @Author : guoxin

# @Time : 2024/5/29 12:09

# @QQ :363673234
class AddGoodsBase:
    def addgoods_button(self):
        """
        新增货源按钮
        :param button_name:
        :return:
        """
        return "//*[@id='app']/div/div[2]/main/div/div/div/div/div/div[1]/div/div/div/div[1]/div/div/div/div[1]/div[1]/span/button[1]/span"

    def addgoods_input(self, input_placeholder):
        """
        新增货源输入框
        :param input_placeholder:
        :return:
        """
        return "//input[@placeholder='" + input_placeholder + "']"

    def addgoods_selecetcarriericon(self):
        # 承运商图标
        return "//*[@id='app']/div/div[2]/main/div/div/div/div/div/div[1]/div/div/div/div[2]/div[1]/div[2]/form/div[1]/div[2]/div/div/div/div/span/span/i"

    def addgoods_selecetcarrier(self):
        # 承运商选择
        return "/html/body/div[3]/div[1]/div[1]/ul/li[1]/span"

    def addgoods_loadxpatedit(self):
        # 装货站点输入框
        return "//label[@for='startStationName']/following-sibling::div"

    def addgoods_onloadstation(self):
        # 装货站点
        return "//div[contains(text(),'绿地中心A座13层')]/ancestor::tr"
        # return "//*[@id='dropdown-menu-8802']/div[1]/div[3]/table/tbody/tr[1]/td[1]/div"

    def addgoods_unloadxpatedit(self):
        # 卸货站点输入框
        return "//label[@for='endStationName']/following-sibling::div"

    def addgoods_unloadxpath(self):
        # 卸货站点弹出框
        # return "//div[contains(text(),'人寿山')]/parent::td"
        # return "//div[contains(text(),'人寿山')]/ancestor::tr"
        # return"//label[@class='el-table_1_column_1   el-table__cell']"
        return "//*[@id=\"dropdown-menu-7162\"]/div/div[3]/table//tr[2]/td/div"
        # return "//*[@id='dropdown-menu-8802']/div[1]/div[3]/table/tbody/tr[2]/td[1]/div"
        # return "//div[contains(text(),'人寿山')]"

    def adddgoos_goosTypexpath(self):
        return "/html/body/div[4]/div[1]/div[1]/ul/li[1]/span"

    def addgoods_submitbutton(self):
        '''
        提交按钮
        :return:
        '''
        return "//*[@id='app']/div/div[2]/main/div/div/div/div/div/div[1]/div/div/div/div[11]/button[2]/span"

    def addgoods_goosNamexpath(self):
        return "//*[@id='el-autocomplete-8083-item-0']"
